package cn.gok.server.service.impl;

import cn.gok.common.dao.customer.CustomerLoginLogDao;
import cn.gok.common.entity.customer.CustomerLoginLog;
import cn.gok.server.service.CustomerLoginLogService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.github.pagehelper.PageInfo;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author: DxlinY
 * @apiNote:
 * @date: 2020/11/7
 * @time: 10:23
 */
@Service
@Slf4j
public class CustomerLoginLogServiceImpl implements CustomerLoginLogService {

    @Autowired
    private CustomerLoginLogDao customerLoginLogDao;

    @Override
    public PageInfo pageInfo(Object target) {
        QueryWrapper <CustomerLoginLog> wrapper = new QueryWrapper <>();
        wrapper.setEntity((CustomerLoginLog) target);
        return new PageInfo(customerLoginLogDao.selectList(wrapper));
    }
}
